import React from "react";
import { Provider } from "mobx-react";
import { createStore } from "../mobx/CreateStore";
import { ThemeProvider, makeStyles } from "@material-ui/styles";
import { BrowserRouter, Route } from "react-router-dom";
import BaseLayout from "./layout/BaseLayout";

const stores = createStore();
/** 定制主题 */
const theme = {};
/** 全局的style */
const useStyles = makeStyles({
  "@global": {
    ".ant-layout-header": {
    }
  }
});

const App: React.FC = () => {
  useStyles()
  return (
    <Provider {...stores}>
      <ThemeProvider theme={theme}>
        <div className="App">
          <BrowserRouter>
            <Route path={"/"} component={BaseLayout} />
          </BrowserRouter>
        </div>
      </ThemeProvider>
    </Provider>
  );
};

export default App;
